<template>
  <div>

    <el-tree
        :check-strictly="true"
        :data="menudata"
        show-checkbox
        node-key="id"
        :check="checkdata"
    >
    </el-tree>
  </div>
</template>
<script>
import service from "@/utils/request";
import ElementUI from "element-ui";


export default {
  data() {
    return {
      checkdata:[1,2,3],
      menudata: [{
        id: 1,
        label: '一级 1',
        children: [{
          id: 2,
          label: '二级 1-1',
          children: [{
            id: 3,
            label: '三级 1-1-1'
          }]
        }]
      }],
      defaultProps: {
        children: 'children',
        label: 'label'
      }
    };
  },
  methods: {
    handleNodeClick(data) {
      console.log(data);
    }
  }
};
</script>

<style scoped>

</style>